home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / include / gnome-vfs-2.0 / libgnomevfs / gnome-vfs-volume-monitor.h < prev    next >
Encoding:
C/C++ Source or Header  |  2006-05-01  |  3.6 KB  |  82 lines

  1. /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
  2. /* gnome-vfs-volume-monitor.h - Handling of volumes for the GNOME Virtual File System.
  3.  
  4.    Copyright (C) 2003 Red Hat, Inc
  5.  
  6.    The Gnome Library is free software; you can redistribute it and/or
  7.    modify it under the terms of the GNU Library General Public License as
  8.    published by the Free Software Foundation; either version 2 of the
  9.    License, or (at your option) any later version.
  10.  
  11.    The Gnome Library is distributed in the hope that it will be useful,
  12.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  13.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  14.    Library General Public License for more details.
  15.  
  16.    You should have received a copy of the GNU Library General Public
  17.    License along with the Gnome Library; see the file COPYING.LIB.  If not,
  18.    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  19.    Boston, MA 02111-1307, USA.
  20.  
  21.    Author: Alexander Larsson <alexl@redhat.com>
  22. */
  23.  
  24. #ifndef GNOME_VFS_VOLUME_MONITOR_H
  25. #define GNOME_VFS_VOLUME_MONITOR_H
  26.  
  27. #include <glib-object.h>
  28. #include <libgnomevfs/gnome-vfs-volume.h>
  29.  
  30. G_BEGIN_DECLS
  31.  
  32. #define GNOME_VFS_TYPE_VOLUME_MONITOR        (gnome_vfs_volume_monitor_get_type ())
  33. #define GNOME_VFS_VOLUME_MONITOR(o)          (G_TYPE_CHECK_INSTANCE_CAST ((o), GNOME_VFS_TYPE_VOLUME_MONITOR, GnomeVFSVolumeMonitor))
  34. #define GNOME_VFS_VOLUME_MONITOR_CLASS(k)    (G_TYPE_CHECK_CLASS_CAST((k), GNOME_VFS_TYPE_VOLUME_MONITOR, GnomeVFSVolumeMonitorClass))
  35. #define GNOME_IS_VFS_VOLUME_MONITOR(o)       (G_TYPE_CHECK_INSTANCE_TYPE ((o), GNOME_VFS_TYPE_VOLUME_MONITOR))
  36. #define GNOME_IS_VFS_VOLUME_MONITOR_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), GNOME_VFS_TYPE_VOLUME_MONITOR))
  37.  
  38. typedef struct _GnomeVFSVolumeMonitorPrivate GnomeVFSVolumeMonitorPrivate;
  39.  
  40. typedef struct _GnomeVFSVolumeMonitor GnomeVFSVolumeMonitor;
  41. typedef struct _GnomeVFSVolumeMonitorClass GnomeVFSVolumeMonitorClass;
  42.  
  43. struct _GnomeVFSVolumeMonitor {
  44.     GObject parent;
  45.  
  46.         GnomeVFSVolumeMonitorPrivate *priv;
  47. };
  48.  
  49. struct _GnomeVFSVolumeMonitorClass {
  50.     GObjectClass parent_class;
  51.     
  52.     void (* volume_mounted)          (GnomeVFSVolumeMonitor *volume_monitor,
  53.                         GnomeVFSVolume           *volume);
  54.     void (* volume_pre_unmount)    (GnomeVFSVolumeMonitor *volume_monitor,
  55.                         GnomeVFSVolume           *volume);
  56.     void (* volume_unmounted)    (GnomeVFSVolumeMonitor *volume_monitor,
  57.                         GnomeVFSVolume           *volume);
  58.     void (* drive_connected)     (GnomeVFSVolumeMonitor *volume_monitor,
  59.                         GnomeVFSDrive           *drive);
  60.     void (* drive_disconnected)    (GnomeVFSVolumeMonitor *volume_monitor,
  61.                         GnomeVFSDrive         *drive);
  62. };
  63.  
  64. GType gnome_vfs_volume_monitor_get_type (void) G_GNUC_CONST;
  65.  
  66. GnomeVFSVolumeMonitor *gnome_vfs_get_volume_monitor   (void);
  67. GnomeVFSVolumeMonitor *gnome_vfs_volume_monitor_ref   (GnomeVFSVolumeMonitor *volume_monitor);
  68. void                   gnome_vfs_volume_monitor_unref (GnomeVFSVolumeMonitor *volume_monitor);
  69.  
  70. GList *         gnome_vfs_volume_monitor_get_mounted_volumes  (GnomeVFSVolumeMonitor *volume_monitor);
  71. GList *         gnome_vfs_volume_monitor_get_connected_drives (GnomeVFSVolumeMonitor *volume_monitor);
  72. GnomeVFSVolume *gnome_vfs_volume_monitor_get_volume_for_path  (GnomeVFSVolumeMonitor *volume_monitor,
  73.                                    const char            *path);
  74. GnomeVFSVolume *gnome_vfs_volume_monitor_get_volume_by_id     (GnomeVFSVolumeMonitor *volume_monitor,
  75.                                    gulong                 id);
  76. GnomeVFSDrive * gnome_vfs_volume_monitor_get_drive_by_id      (GnomeVFSVolumeMonitor *volume_monitor,
  77.                                    gulong                 id);
  78.  
  79. G_END_DECLS
  80.  
  81. #endif /* GNOME_VFS_VOLUME_MONITOR_H */
  82.